package io.zhaocy.springbootenable.annotation;

import java.lang.reflect.Method;

/**
 * Description:
 *
 * @Author: genezhao
 * @Date: 2018-07-13
 */
public class Single {

    @MySingle(100)
    public static void myMeth() {

        Single single = new Single();

        try {
            Method m = single.getClass().getMethod("myMeth");
            MySingle ms = m.getAnnotation(MySingle.class);

            System.out.println(ms.value());
        } catch (NoSuchMethodException e) {
            e.printStackTrace();
        }
    }


    public static void main(String[] args) {
        myMeth();
    }
}
